;菲波拉契数列
(define (rab N)
  (cond [(or (= N 1) (= N 2)) 1]
        [else (+ (rab (- N 1)) (rab (- N 2)))]))

;求list元素相加的和
(define (sum a-list)
  (cond
    [(= 0 (length a-list)) 0]
    [else (+ (car a-list) (sum (cdr a-list)))]))

;求list中元素的个数
(define (how-many a-list)
  (length a-list))

;依次打印出list中所有元素
(define (print a-list)
  (cond 
        [(= (length a-list) 1) (display (car a-list))]
        [(> (length a-list) 1) (display (car a-list))
                               (display "\n")
                               (print (cdr a-list))]
  )
)

(define (prlist a-list)
  (display a-list)
  (display "\n")
  (display a-list)
  (display "\n")
  )